<script setup>
import { ref,onMounted  } from 'vue'
import {zyOffice} from '/public/zyoffice/js/w'
import '/public/UEditor/ueditor.config'
import '/public/UEditor/ueditor.all.min'
import '/public/layer-v3.1.1/layer/layer'
import '/public/layer-v3.1.1/layer/theme/default/layer.css'
import '/public/layer-v3.1.1/layer/theme/default/layer.css'

const msg = '<h2>zyOffice for vue3-cli-ueditor</h2>'
const editorConfig={
    UEDITOR_HOME_URL: '/public/UEditor/', // 访问 UEditor 静态资源的根路径，可参考常见问题1
    serverUrl: '//ueditor.szcloudplus.com/cos', // 服务端接口（这个地址是我为了方便各位体验文件上传功能搭建的临时接口，请勿在生产环境使用！！！）
}
//初始化
zyOffice.getInstance({
    word: 'http://localhost:13710/zyoffice/word/convert',
    wordExport: 'http://localhost:13710/zyoffice/word/export',
    pdf: 'http://localhost:13710/zyoffice/pdf/upload'    
});

function ueready(edt){  
}

</script>

<template>
  <vue-ueditor-wrap v-model="msg" :config="editorConfig" editor-id="editor1" @ready="ueready"></vue-ueditor-wrap>
  <p>第二个编辑器</p>
  <vue-ueditor-wrap v-model="msg" :config="editorConfig" editor-id="editor2" @ready="ueready"></vue-ueditor-wrap>  
</template>

<style scoped>
a {
  color: #42b983;
}
</style>
